package com.party.business.service.impl;

import java.util.List;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.party.business.mapper.TopicLibraryMapper;
import com.party.business.domain.TopicLibrary;
import com.party.business.service.ITopicLibraryService;

/**
 * 专题Service业务层处理
 *
 * @author ruoyi
 * @date 2025-06-18
 */
@Service
public class TopicLibraryServiceImpl extends ServiceImpl<TopicLibraryMapper,TopicLibrary>  implements ITopicLibraryService
{
    @Autowired
    private TopicLibraryMapper topicLibraryMapper;

    /**
     * 查询专题
     *
     * @param id 专题主键
     * @return 专题
     */
    @Override
    public TopicLibrary selectTopicLibraryById(Long id)
    {
        return topicLibraryMapper.selectTopicLibraryById(id);
    }

    /**
     * 查询专题列表
     *
     * @param topicLibrary 专题
     * @return 专题
     */
    @Override
    public List<TopicLibrary> selectTopicLibraryList(TopicLibrary topicLibrary)
    {
        return topicLibraryMapper.selectTopicLibraryList(topicLibrary);
    }

    /**
     * 新增专题
     *
     * @param topicLibrary 专题
     * @return 结果
     */
    @Override
    public int insertTopicLibrary(TopicLibrary topicLibrary)
    {
            return topicLibraryMapper.insertTopicLibrary(topicLibrary);
    }

    /**
     * 修改专题
     *
     * @param topicLibrary 专题
     * @return 结果
     */
    @Override
    public int updateTopicLibrary(TopicLibrary topicLibrary)
    {
        return topicLibraryMapper.updateTopicLibrary(topicLibrary);
    }

    /**
     * 批量删除专题
     *
     * @param ids 需要删除的专题主键
     * @return 结果
     */
    @Override
    public int deleteTopicLibraryByIds(Long[] ids)
    {
        return topicLibraryMapper.deleteTopicLibraryByIds(ids);
    }

    /**
     * 删除专题信息
     *
     * @param id 专题主键
     * @return 结果
     */
    @Override
    public int deleteTopicLibraryById(Long id)
    {
        return topicLibraryMapper.deleteTopicLibraryById(id);
    }
}
